package com.dji.model;

import java.util.UUID;

/**
 * 表示大疆无人机的模型类
 */
public class Drone {
    private String id;
    private String model;
    private double batteryLevel;
    private double altitude;
    private double latitude;
    private double longitude;
    private double speed;
    private String status; // 飞行状态：IDLE, FLYING, RETURNING, LANDING
    
    public Drone() {
        this.id = UUID.randomUUID().toString();
        this.batteryLevel = 100.0;
        this.altitude = 0.0;
        this.latitude = 0.0;
        this.longitude = 0.0;
        this.speed = 0.0;
        this.status = "IDLE";
    }
    
    public Drone(String model) {
        this();
        this.model = model;
    }

    // Getters and Setters
    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getModel() {
        return model;
    }

    public void setModel(String model) {
        this.model = model;
    }

    public double getBatteryLevel() {
        return batteryLevel;
    }

    public void setBatteryLevel(double batteryLevel) {
        this.batteryLevel = batteryLevel;
    }

    public double getAltitude() {
        return altitude;
    }

    public void setAltitude(double altitude) {
        this.altitude = altitude;
    }

    public double getLatitude() {
        return latitude;
    }

    public void setLatitude(double latitude) {
        this.latitude = latitude;
    }

    public double getLongitude() {
        return longitude;
    }

    public void setLongitude(double longitude) {
        this.longitude = longitude;
    }

    public double getSpeed() {
        return speed;
    }

    public void setSpeed(double speed) {
        this.speed = speed;
    }

    public String getStatus() {
        return status;
    }

    public void setStatus(String status) {
        this.status = status;
    }
}